<?php
switch ($_REQUEST['action']){
	case "get":
		if($_REQUEST['type'] == "xml") {
			header("Content-type:text/xml");
			echo <<<XML
			<data>
				<some>content</some>
			</data>
XML;
		}
		break;
	case "post":
		echo $_REQUEST['from'];
		break;
	default:
		echo "<div id='result'>Ajax Return Content</div>";
		break;
}
